import request from '@utils/ajax'

export const getResourceList = data => {
  return request({
    url: 'applet/carshopSource/list',
    auth: false,
    data: {
      ...data,
      size: 10
    }
  })
}
export const getResourceDetail = carshop_car_id => {
  return request({
    url: 'applet/carshopSource/detail',
    showLoading: true,
    data: {
      carshop_car_id
    }
  })
}
export const getFindList = data => {
  return request({
    url: 'applet/lookCar/list',
    auth: false,
    data: {
      ...data,
      size: 10
    }
  })
}
export const getFindDetail = id => {
  return request({
    url: 'applet/lookCar/detail',
    showLoading: true,
    data: {
      id
    }
  })
}
export const publishFind = data => {
  return request({
    url: 'applet/lookCar/submit',
    data,
    method: 'POST'
  })
}
export const publishResource = data => {
  return request({
    url: 'applet/carshopSource/submit',
    data,
    method: 'POST'
  })
}
export const dockFind = data => {
  return request({
    url: 'applet/lookCar/dockingSuccess',
    data,
    method: 'POST'
  })
}
export const reportResource = data => {
  return request({
    url: 'applet/carshopSource/accusation',
    data,
    method: 'POST'
  })
}
// 车商车源对接
export const dockResource = data => {
  return request({
    url: 'applet/carshopSource/dockingSuccess',
    data,
    method: 'POST'
  })
}
